#ifndef __MMOPEON_GUI_SELECTIONPANEL
#define __MMOPEON_GUI_SELECTIONPANEL

/* Copyright (C) 2011 clueless <clueless.mmopeon@gmail.com>
 *
 * This file is part of MMO Peon.
 *
 * MMO Peon is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * MMO Peon is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with MMO Peon.  If not, see <http://www.gnu.org/licenses/>.
 */
#include <wx/wx.h>
#include <wx/listctrl.h>

struct RomProcessInfo
{
    wxString title;
    wxString pid;
};

class SelectionPanel : public wxPanel
{
    public:
        SelectionPanel(wxWindow* parent);
        ~SelectionPanel();

    private:
        void    SetEventHandlers();
        wxVector<RomProcessInfo> CreateProcessList();
        void    UpdateOpenProcesses(wxVector<RomProcessInfo>& procList);
        void    UpdateClosedProcesses(wxVector<RomProcessInfo>& procList);

        void    OnSelectChanged(wxCommandEvent& WXUNUSED(event));
        void    OnOpenProcess(wxCommandEvent& WXUNUSED(event));
        void    OnCloseProcess(wxCommandEvent& WXUNUSED(event));
        void    OnTimer(wxCommandEvent& WXUNUSED(event));

        wxTimer*        timer;
        wxButton*       openButton;
        wxButton*       closeButton;
        wxListCtrl*     closedProcesses;
        wxListCtrl*     openProcesses;
};

#endif
